package engine;

import java.awt.Graphics;
import java.awt.Point;
import java.awt.Rectangle;


/**
 * Sprite.java
 * Basic Game Object with shared paint and bounds-defining methods
 * 
 * @author Connor Gordon, Niel Lebeck
 * 
 */
public abstract class Sprite {
    private Point myPosition;

    /**
     * Sets new absolute position of the sprite
     * 
     * @param newPosition updated Coordinate
     */
    public void setPosition (Point newPosition) {
        myPosition = newPosition;
    }

    /**
     * Returns absolute position of sprite
     * 
     * @return coordinate of Sprite
     */
    public Point getPosition () {
        return myPosition;
    }

    /**
     * Paints the Sprite @ a relative location, determined by the Camera's
     * offsetX and offsetY
     * 
     * @param g Graphics drawing object
     * @param offsetX relative X point of origin
     * @param offsetY relative Y point of origin
     */
    public abstract void paint (Graphics g, int offsetX, int offsetY);

    public abstract Rectangle getBounds ();
}
